<template>
  <div class="container">
    <subject-table></subject-table>
    <add-form></add-form>
  </div>
</template>

<script>
import AddForm from "./components/AddForm.vue";
import SubjectTable from "./components/SubjectTable.vue";
/*
  学习目标：组件拆分和注册
     1. 素材中的, 复制代码到App.vue
     2. 回复样式
  步骤：
     3. 新建2个子组件： AddForm SubjectTable
     4. 导入注册
*/

export default {
  components: { SubjectTable, AddForm },
  name: "App",
  data() {
    return {
      list: [
        {
          id: 100,
          subject: "语文",
          score: 99,
          time: new Date("2010-08-12"),
        },
        {
          id: 101,
          subject: "数学",
          score: 34,
          time: new Date("2020-09-01"),
        },
        {
          id: 102,
          subject: "英语",
          score: 25,
          time: new Date("2018-11-22"),
        },
        {
          id: 103,
          subject: "体育",
          score: 100,
          time: new Date("2020-12-12"),
        },
      ],
    };
  },
};
</script>

<style scoped></style>
